package br.com.vemtransporte.util;

import android.app.Activity;
import android.content.Context;
import android.os.Environment;
import android.view.inputmethod.InputMethodManager;

public class Utils {

	public static String getDirSDCard() {
		return Environment.getExternalStorageDirectory().getPath();
	}

	public static void ShowKeyboard(boolean visible, Activity a) {
		InputMethodManager imm = (InputMethodManager) a
				.getSystemService(Context.INPUT_METHOD_SERVICE);

		if (imm != null) {
			if (visible){
				imm.toggleSoftInput(InputMethodManager.SHOW_FORCED, 0);
			}else{
				imm.toggleSoftInput(InputMethodManager.HIDE_IMPLICIT_ONLY, 0);
			}
		}

	}

}
